Forwarded: not-needed
Inline getprogname() by using program_invocation_short_name
when available (like with glibc).
This makes a lot of binaries to avoid linkage to libreplace.
This is a short and dirty version, proper change for upstream
should clean up #ifdef'fery in replace.c.
Gbp-Pq: Name inline-getprogname.diff
}
#endif /* HAVE_MEMSET_S */
-#ifndef HAVE_GETPROGNAME
+#if !defined(HAVE_GETPROGNAME) && !defined(HAVE_PROGRAM_INVOCATION_SHORT_NAME)
# ifndef HAVE_PROGRAM_INVOCATION_SHORT_NAME
# define PROGNAME_SIZE 32
static char rep_progname[PROGNAME_SIZE];
#endif
#ifndef HAVE_GETPROGNAME
+#ifdef HAVE_PROGRAM_INVOCATION_SHORT_NAME
+# define getprogname() (program_invocation_short_name)
+#else
#define getprogname rep_getprogname
const char *rep_getprogname(void);
#endif
+#endif
#ifndef HAVE_COPY_FILE_RANGE
#define copy_file_range rep_copy_file_range